Method for abstracting histogram of hsv color

ABSTRACT

A method for abstracting a HSV histogram from an input image saved YCbCr in a YCbCr model is disclosed, which includes a) forming a LUT divided into a plurality of sections which can print out a quantified index value by receiving an input YCbCr and in which the quantified index value of each section is saved, b) selecting one section from the LUT according to a Y signal or a CbCr signal of the input YCbCr model, and c) abstracting the histogram using the index of the selected section. Thus, the speed of abstracting the histogram can be increased hundreds or thousands times as fast as a related art by omitting processes of converting the image saved in the YCbCr model to the HSV model and of quantifying the YCbCr model.

TECHNICAL FIELD

The present invention relates to a method for abstracting a histogram ofHSV colors, and more particularly, to a method for fast abstraction of ahistogram of HSV colors from a still or motion picture stored in a YCbCrformat.

BACKGROUND ART

Recently, as use of digital video increases rapidly, starting from videosearch by means of video indexing, or content basis search by using animage, development of a variety of multimedia service systems has beenmade. Most of content basis search systems by using images use a methodin which proper characteristic vectors are abstracted from the images,and a similarity of the images are determined with reference to asimilarity of the characteristic vectors. Of different imagecharacteristics, an HSV (Hue-Saturation-Value) Color Histogram is usedwidely as the most typical image characteristic.

There are a variety of methods for expressing a color, by usingdifferent color models depending on application, such as RGB (Red,Green, and Blue; a color model for expressing a color with three primarycolor of red, green, and blue), CMY (Cyan, Magenta, and Yellow; atypical color model in a printing field), YCbCr (Gamma transformedluminance/color difference separation color model), HSV (typical colormodel used in a Computer Graphic field), and the like.

Of the different color models, the YCbCr color model, very efficient incompressing a picture data, is used in most of picture compressinginternational standards, such as JPEG (Joint Photographic Coding ExpertsGroup), MPEG (Moving Picture Experts Group), and the like. The YCbCrcolor model indicates ratios of three components of luminanceinformation ‘Y’, color difference information ‘Cb’, and ‘Cr’ included ina horizontal line of a TV screen and the like, wherein the luminance ofa pixel is represented with 8 bits, and the color of the pixel isrepresented with the color difference information by using two 8 bits.

However, since the YCbCr color model is far from human perceptioncharacteristics, the HSV color model, which reflects the humanperception characteristics the best, is mostly used in abstracting thecharacteristic vectors from the picture. That is, a YCbCr color space isconverted into an HSV color space of a Hue, Saturation, and Value beforeusing the YCbCr color.

FIG. 1 illustrates a block diagram of a related art HSV color histogramabstractor.

The related art HSV color histogram abstractor, for abstracting a HSVcolor histogram from the YCbCr color model, is provided with a YCbCr/HSVconverter 101 for converting a pixel value from the YCbCr color model tothe HSV color model, a quantizer 102 for quantizing the HSV color modelconverted at the YCbCr/HSV converter 101 to provide a histogram index,and a histogram generator 103 for increasing a histogram BIN value ofthe histogram index from the quantizer 102 by one, to generate ahistogram.

A related art method for abstracting an HSV color histogram from theYCbCr color model will be described.

For abstracting the HSV color histogram from the picture stored in theYCbCr color model, the YCbCr/HSV converter 101 converts a pixel valuefrom the YCbCr color model to the HSV color model with the followingequations. $\begin{matrix}{{H = {{\tan^{- 1}\frac{{Cr}\text{-}128}{{Cr}\text{-}128}S\frac{180}{\pi}} - 180}},{0\quad D\quad{HD}\quad 360}} & (1) \\{{S = \sqrt{\left( {{Cr}\text{-}128} \right)^{2} + \left( {{Cb}\text{-}128} \right)^{2}}},{0D\quad{SD}\quad 128}} & (2) \\{{V = Y},{0 \leq V \leq 255}} & (3)\end{matrix}$

Then, the quantizer 102 quantizes the pixel value of the HSV model, toobtain a histogram index. As an example of an actual quantization whichcan be used effectively in the content basis image search application, acase of quantization as shown in FIG. 3 will be described.

Referring to FIG. 3A, the HSV model is represent with a threedimensional (HSV) cylindrical coordinate system, in which an axis of thecylinder represents ‘V’, a concentric circular direction starting from acenter (O) represents ‘S’, and an angle represents ‘H’. A method forquantizing the three dimensional HSV space represented thus isillustrated in sections of an HS plane and an SV plane.

That is, a pixel, having an ‘S’ equal to or smaller than 5, is regardedas a gray scale, and quantized only with respect to ‘V’ in four stageseach with 64 levels regardless of an H value.

A color, having the ‘S’ greater than 5 and equal to or smaller than 30,is quantized with respect to ‘H’ in six stages each with 60 degrees, and‘V’ in two stage each with 128 levels. A color, having the ‘S’ greaterthan 30, is quantized only with respect to ‘H’ in six stages each with60 degrees while disregarding ‘V’.

A part having the S greater than 30 is quantized coarser than a parthaving the S smaller than 30 for reflecting a probability thatoccurrence of great S is relatively small in natural pictures. Thus, ahistogram having 22 BINs (four stages with respect to ‘V’ for a pixelhaving S smaller than 5, six stages with respect to ‘H’ and two stagewith respect to ‘V’ (2×6) for a color having an S greater than 5 andsmaller than 30, and six stages with respect to ‘H’ for a color havingan S greater than 30) is drawn up. The quantizer 102 determines a givenpixel value of being a point belonging to which of 22 sections dividedby circular, and radial boundaries in the three dimensional HSV space,and provides an index value between 0 to 21 representing the section.Every time the quantization index is obtained, the histogram generatingpart 103 increases a BIN value of the histogram for the index by one, todraw up the histogram.

However, the related art method for abstracting an HSV color histogramfrom a picture in the YCbCr color model has the following problems.

That is, even though the HSV color histogram is drawn up if theforegoing process is carried out for all pixels, the square rootoperation and the arctan function operation in the equations (1) and (2)for converting the YCbCr color model to the HSV color model costs veryhigh.

DISCLOSURE OF INVENTION

An object of the present invention designed to solve the foregoingproblem lies on providing a method for abstracting an HSV colorhistogram from a YCbCr format picture, not by using a related art methodin which a picture stored in a YCbCr color model is converted into anHSV model, and the converted HSV color model is quantized in an HSVspace, but by receiving the YCbCr color model in advance, making aLookup table (LUT) which can provide a histogram index, and abstractingthe HSV histogram with reference to the lookup table, for dispensingwith the complicate operations.

The object of the present invention can be achieved by providing amethod for abstracting a histogram of HSV colors, including the steps ofdrawing up lookup tables each divided into a plurality of sections eachhaving a quantizing index value stored therein, for receiving a YCbCrand providing an HSV histogram index, selecting one section of thelookup table according to a Y signal and a CbCr signal of a YCbCr model,and abstracting the histogram with reference to the index of theselected section.

Preferably, in a case H, S, and V are respectively quantized in L, M,and N levels, the step of drawing up lookup tables includes the steps ofdrawing up N lookup tables corresponding to Cb and Cr, dividing each ofthe N lookup tables with M concentric circles corresponding to Squantizing boundaries from a center, dividing each of the N lookuptables with L radial lines to form sections, and storing a quantizingindex in each of sections of the N lookup tables.

Preferably, a number of the lookup tables is four, each divided byconcentric circles with 5, and 30 radii from the center respectively,and by six radial lines again for sections with a radius greater than 5,for storing quantizing indices therein respectively.

In another aspect of the present invention, there is provided a methodfor abstracting a histogram of HSV colors in a case H, S, and V arerespectively quantized in L, M, and N levels, comprising the stepsdrawing up N lookup tables corresponding to Cb and Cr, dividing each ofthe N lookup tables with M concentric circles corresponding to Squantizing boundaries from a center, dividing each of the N lookuptables with L radial lines to form sections, storing a quantizing indexin each of sections of the N lookup tables, shifting a luminance signalY of received YCbCr to right by (8-log2N) bits when N is a power of 2,and dividing Y with N when N is not a power of 2, and selecting one ofthe N lookup tables, and picking up a value of a section correspondingto Cb and Cr.

BRIEF DESCRIPTION OF DRAWINGS

The accompanying drawings, which are included to provide a furtherunderstanding of the invention, illustrate embodiment(s) of theinvention and together with the description serve to explain theprinciple of the invention. In the drawings;

FIG. 1 illustrates a block diagram of abstracting an HSV color histogramfrom a YCbCr format picture in the related art;

FIG. 2 illustrates a block diagram of abstracting an HSV color histogramfrom a YCbCr format picture in accordance with a preferred embodiment ofthe present invention;

FIGS. 3A˜3C illustrate an example of a quantizing method in an HSV spacein accordance with the present invention; and

FIG. 4 illustrates an exemplary diagram for describing a method formaking and referring to an LUT of the present invention.

BEST MODE FOR CARRYING OUT THE INVENTION

Reference will now be made in detail to the preferred embodiments of thepresent invention, examples of which are illustrated in the accompanyingdrawings. In describing the embodiments of the present invention, sameparts will be given the same names and reference symbols, and repetitivedescription of which will be omitted.

A method for abstracting a histogram of HSV colors from a YCbCr formatpicture in accordance with a preferred embodiment of the presentinvention will be described with reference to the attached drawings.

The system and operation of the present invention will be describedtaking a case of quantization as illustrated in FIG. 3 as an example.

Referring to FIG. 4, four lookup tables LUT1˜LUT4 each with 256×256height and width size in correspondence to Cb and Cr are drawn up inadvance. Each of the lookup tables LUT1˜LUT4 is divided by concentriccircles with radii 5 and 30 from a center (0, 0), and six radial linesat 60° intervals starting from 138° for a section thereof outside ofradius 5. The section is divided by six radial lines at 60° intervalsstarting from 138° because an 108° on a Cb, or Cr plane corresponds to0° on an H plane, i.e., for dividing the lookup table into six sectionsat 60° intervals centered on 0° of an H plane, it is required to drawsix radial lines at 60° intervals centered on 108°, resulting to obtaina section from 138° to 78°, which is 108°±30°, and divide the lookuptable with radial lines at 60° intervals starting from 138°.

Referring to FIG. 4, a quantizing index value is stored in each sectionof the lookup table.

That is, referring to FIG. 3C, since the section with a radius below 5on the SV plane is divided in four stages each with 64 levels, fourlookup tables are drawn up, and different quantizing index values arerespectively stored in the sections of the lookup tables with radiibelow 5 accordingly (a quantizing value of “0” is stored in LUT1, aquantizing value of “1” is stored in LUT2, a quantizing value of “2” isstored in LUT3, and a quantizing value of “3” is stored in LUT4).

Also, since a section having a radius greater than 5 but smaller than 30on the SV plane is divided into two sections, though identicalquantizing values are stored in sections of the first and second lookuptables LUT1 and LUT2 each with a radius greater than 5 but below 30, andidentical quantizing values are stored in sections of the third andfourth lookup tables LUT3 and LUT4 each with a radius greater than 5 butbelow 30, different quantizing values are stored in sections of thefirst and second lookup tables LUT1 and LUT2, and the third and fourthlookup tables LUT3 and LUT4, each with a radius greater than 5 but below30.

Also, since a section on the SV plane with a radius greater than 30 isnot divided, identical quantizing values are stored in sections of thelookup tables each with a radius greater than 30.

A method for abstracting a histogram of HSV colors from the YCbCr colormodel of the present invention by using the lookup tables drawn up thuswill be described.

When a pixel value of the YCbCr color model is provided, by shifting aluminance signal ‘Y’ to right, one of the four lookup tables is selectedwith reference to a value corresponding to the most significant twobits, where a value corresponding to Cb and Cr can be obtained, which isthe quantizing index at the time converted into the HSV model andquantized.

The lookup tables drawn up thus can be summarized as follows.

In a case H, S, and V are respectively quantized in L, M, and N levels,after preparing a system in which ‘N’ lookup tables each with a 256×256size corresponding to Cb and Cr are drawn up, so that one of N lookuptables is selected by shifting Y to right by (8-log2N) bits when N is apower of 2, and subjecting Y to an integer dividing operation with Nwhen N is not a power of 2, and a value corresponding to Cb and Cr ispicked up from the lookup table, and after dividing each of the lookuptable with M concentric circles for a range starting from a 128 radiusfrom a center of the lookup table to an ‘S’ radius quantizingboundaries, and with L radial lines at regular intervals, a quantizingindex is stored in each section. Once the lookup tables are drawn upthus, the steps of converting the pixel value from the YCbCr space tothe HSV space, and quantizing the pixel value in the HSV space can bereplaced with only one step of referring to the lookup tables, that isvery simple.

INDUSTRIAL APPLICABILITY

As has been described, the method for abstracting a histogram of HSVcolors from a YCbCr format of the present invention has the followingadvantages.

In abstracting the HSV color histogram from a picture stored in a YCbCrmodel, by simplifying the steps of converting the YCbCr model to the HSVmodel, and quantizing the HSV model in the HSV space into one step ofreferring to the lookup tables, a speed of abstracting the histogram canbe improved a few hundred times.

Moreover, the abstracting method of the present invention is useful notonly in a case when an HSV color histogram is abstracted from a stillpicture stored in a format, such as JPEG, but also in a case a fastprocessing of a large amount of data, such as analyzing a large amountof digital video, such as an HDTV broadcasting stream.

1. A method for abstracting a histogram of HSV colors, comprising thesteps of: drawing up lookup tables each divided into a plurality ofsections each having a quantizing index value stored therein, forreceiving a YCbCr and providing an HSV histogram index; selecting onesection of the lookup table according to a Y signal and a CbCr signal ofa YCbCr model; and abstracting the histogram with reference to the indexof the selected section.
 2. The method as claimed in claim 1, wherein,in a case H, S, and V are respectively quantized in L, M, and N levels,the step of drawing up lookup tables includes the steps of; drawing up Nlookup tables corresponding to Cb and Cr, dividing each of the N lookuptables with M concentric circles corresponding to S quantizingboundaries from a center, dividing each of the N lookup tables with Lradial lines to form sections, and storing a quantizing index in each ofsections of the N lookup tables.
 3. The method as claimed in claim 2,wherein a number of the lookup tables is four, each divided byconcentric circles with 5, and 30 radii from the center respectively,and by six radial lines again for sections with a radius greater than 5,for storing quantizing indices therein respectively.
 4. A method forabstracting a histogram of HSV colors in a case H, S, and V arerespectively quantized in L, M, and N levels, comprising the steps:drawing up N lookup tables corresponding to Cb and Cr; dividing each ofthe N lookup tables with M concentric circles corresponding to Squantizing boundaries from a center; dividing each of the N lookuptables with L radial lines to form sections; storing a quantizing indexin each of sections of the N lookup tables; shifting a luminance signalY of received YCbCr to right by (8-log2N) bits when N is a power of 2,and dividing Y with N when N is not a power of 2, and selecting one ofthe N lookup tables; and picking up a value of a section correspondingto Cb and Cr.